﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Threading.Tasks;
using Volo.Abp.Modularity;
using Xunit;

namespace RH.Template.Test
{
    /* Write your custom repository tests like that, in this project, as abstract classes.
     * Then inherit these abstract classes from EF Core & MongoDB test projects.
     * In this way, both database providers are tests with the same set tests.
     */
    public abstract class SampleRepository_Tests<TStartupModule> : RHTemplateTestBase<TStartupModule>
        where TStartupModule : IAbpModule
    {
        private readonly ITestAppService testAppService;

        protected SampleRepository_Tests()
        {
            testAppService = GetRequiredService<ITestAppService>();
        }

        [Fact]
        public async Task Method1Async()
        {
            try
            {
               await testAppService.GetTestData();
                Assert.True(true);

            }
            catch (Exception)
            {
                Assert.True(false);
            }
        }
    }

}
